package com.geek.javase.ch06.test3;

import java.util.Calendar;

/*
 *@author wangpeng
 *2025/10/14 22:47
 *@description TODO
 */
//6.请问今天是今年的第多少天？
public class Demo6 {
    public static void main(String[] args) {
        Calendar calendar = Calendar.getInstance();
        // 获取当前年份的第几天
        int dayOfYear = calendar.get(Calendar.DAY_OF_YEAR);
        System.out.println("今天是今年的第" + dayOfYear + "天");
    }

}
